package com.ccz.demo.design.state.event;

import com.ccz.demo.design.state.AbstractStatus;
import com.ccz.demo.design.state.ActivityService;
import com.ccz.demo.design.state.ActivityStatus;
import com.ccz.demo.design.state.Result;
import lombok.extern.slf4j.Slf4j;

@Slf4j
public class EditStatus extends AbstractStatus {



    @Override
    public Result checkPass(String id, Enum<ActivityStatus> currentStatus) {
        ActivityService.execStatus(id, currentStatus, ActivityStatus.PASS);

        return new Result("0", "活动审核通过");
    }

    @Override
    public Result checkRefuse(String id, Enum<ActivityStatus> currentStatus) {
        ActivityService.execStatus(id, currentStatus, ActivityStatus.REFUSE);
        return new Result("0", "活动审核拒绝");
    }

    @Override
    public Result activityFinish(String id, Enum<ActivityStatus> currentStatus) {
        return new Result("-1", "未通过活动不可完成");
    }

    @Override
    public Result activityCancel(String id, Enum<ActivityStatus> currentStatus) {
        return new Result("-1", "未通过活动不可取消");
    }
}
